package gdr.dev.creator;

import java.awt.Color;

import gdr.battle.core.CPUClient;
import gdr.battle.ia.DumbestIA;
import gdr.player.*;
import gdr.battle.core.*;

public class TeamCreator {
	
	public static Team createTeam(BattleContainer bc, String name, Color colore){
		Team team = new Team();
		team.setName(name);
		team.setColoreTeam(colore);
		bc.getData().addTeam(team);
		bc.getData().getGestoreTurni().getListaTurni().add(team);
		return team;
	}

	public static CPUClient createCPUClient(BattleContainer bc, Team team){
		CPUClient cpu = new CPUClient(bc.getManager().getGdr());
		cpu.setContainer(bc);
		cpu.init();
		cpu.setClientTeam(team);
		DumbestIA ia = new DumbestIA(bc, team);
		cpu.setIa(ia);
		return cpu;
	}
}
